#include <iostream>

int Hash(char i)
{
    return i - 'a';
}

int main()
{
    int hash[26] = {0}; // 准备一个哈希表
    std::string s1 = "aello";
    std::string s2 = "loeh";

    for (int i = 0; i < s1.size(); i++)
    {
        hash[Hash(s1[i])]++;  
    }
    for (int i = 0; i < s2.size(); i++)
    {
        hash[Hash(s2[i])]--; 
    }

    int count = 0;
    for (int i = 0; i < 26; i++)
    {
        if (hash[i] != 0)
        {
            count += hash[i];   // 差几个，就变几个
        }
    }
    // std::cout << "是字母异位词" << std::endl;
    std::cout<<count<<std::endl;
    return 0;
}
